from basic.basic_driver import DRIVER
from basic.basic_page import BasicPage
from time import sleep
class PageServiceCart(BasicPage):
    def add_to_cart(self):
        """
        加入购物车
        :return: None
        """
        value = "new UiSelector().text(\"加入购物车\")"
        self.click(value)
        sleep(3)
        value = "new UiSelector().text(\"加入购物车\")"
        self.click(value)
        sleep(3)
        value = "new UiSelector().text(\"购物车\")"
        self.click(value)
        sleep(3)
        return DRIVER.current_activity

    def buy_now(self):
        pass


